#include <iostream>
using namespace std;

void f(int& a){
    cout << "The value of the var :" << a << endl;
    cout << "The adress of the var :" << &a << endl;

    a=22;

    //thats all
}

int main(){

    int x=55;

    // aynı pass vy value gibi görünüyor !
    f(x);
    cout << "The reference result here :" << x << endl;
    cout << "The reference result here adress :" << &x << endl;

    int *b=&x;
    f(*b);

    cout << "Bir de bakalım pointer sallsak ne olcek :"<< endl;
    cout << "The reference result here (value):" << *b << endl;
    cout << "The reference result here (adress of value ):" << b << endl;
    cout << "The reference result here (adres of adress):" << &b << endl;

    cout << "****************TYPEDEF DENEMESI ******************" << endl;

    typedef int* int_ptr;

    int_ptr c = &x;
    f(*c);

    cout << "The reference result here (value):" << *c << endl;
    cout << "The reference result here (adress of value ):" << c << endl;
    cout << "The reference result here (adres of adress):" << &c << endl;




    return 0;
}
